package com.slz3.business.module.wmsManagement.wmsWarningConfig.steward;

import com.slz3.business.frame.response.RR;
import com.slz3.business.frame.response.ResInfo;
import com.slz3.business.module.wmsManagement.wmsWarningConfig.domain.WmsWarningConfig;
import com.slz3.business.module.wmsManagement.wmsWarningConfig.domain.WmsWarningConfigCondition;
import org.springframework.web.reactive.function.server.ServerRequest;
import org.springframework.web.reactive.function.server.ServerResponse;
import reactor.core.publisher.Mono;

public class WmsWarningConfigResAtomic extends WmsWarningConfigResExecutor {

    public Mono<ServerResponse> add_$WmsWarningConfigUpdateLock(ServerRequest req, WmsWarningConfig wmsWarningConfig) {
        return WmsWarningConfigResSafeValid.add(req, wmsWarningConfig) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.add(req, wmsWarningConfig);
    }

    public Mono<ServerResponse> delete_$WmsWarningConfigUpdateLock(ServerRequest req, WmsWarningConfigCondition wmsWarningConfigCondition) {
        return WmsWarningConfigResSafeValid.delete(req, wmsWarningConfigCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.delete(req);
    }

    public Mono<ServerResponse> modify_$WmsWarningConfigUpdateLock(ServerRequest req, WmsWarningConfig wmsWarningConfig) {
        return WmsWarningConfigResSafeValid.modify(req, wmsWarningConfig) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.modify(req, wmsWarningConfig);
    }

    public Mono<ServerResponse> info_$WmsWarningConfigUpdateLock(ServerRequest req) {
        return WmsWarningConfigResSafeValid.info(req) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.info(req);
    }

    public Mono<ServerResponse> auditSubmit_$WmsWarningConfigUpdateLock(ServerRequest req, WmsWarningConfigCondition wmsWarningConfigCondition) {
        return WmsWarningConfigResSafeValid.auditSubmit(req, wmsWarningConfigCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.auditSubmit(req);
    }

    public Mono<ServerResponse> audit_$WmsWarningConfigUpdateLock(ServerRequest req, WmsWarningConfigCondition wmsWarningConfigCondition) {
        return WmsWarningConfigResSafeValid.audit(req, wmsWarningConfigCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.audit(req);
    }

    public Mono<ServerResponse> auditReject_$WmsWarningConfigUpdateLock(ServerRequest req, WmsWarningConfigCondition wmsWarningConfigCondition) {
        return WmsWarningConfigResSafeValid.auditReject(req, wmsWarningConfigCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.auditReject(req);
    }


    public Mono<ServerResponse> usingEnable_$WmsWarningConfigUpdateLock(ServerRequest req, WmsWarningConfigCondition wmsWarningConfigCondition) {
        return WmsWarningConfigResSafeValid.usingEnable(req, wmsWarningConfigCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.usingEnable(req);
    }

    public Mono<ServerResponse> usingDisable_$WmsWarningConfigUpdateLock(ServerRequest req, WmsWarningConfigCondition wmsWarningConfigCondition) {
        return WmsWarningConfigResSafeValid.usingDisable(req, wmsWarningConfigCondition) ?
                RR.fail(req, ResInfo.builder().theme(RR.SAFE_VALID).build()) :
                super.usingDisable(req);
    }
}
